package com.wzx.shop.pojo;

import com.baomidou.mybatisplus.annotation.*;
import com.wzx.shop.common.BasePojo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;

/**
 * @author wzx
 * @version 1.0
 * @date 2022/9/3 - 12:54
 * @description 标题
 */
@Data
@TableName("t_shop_commodity")
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "ShopCommodity", description = "商品")
public class ShopCommodity extends BasePojo {

    @TableId(value = "shopId", type = IdType.AUTO)
    @ApiModelProperty(notes = "主键id", required = true)
    private Integer shopId;

    @TableField("commodityName")
    @ApiModelProperty(value = "商品名称")
    private String commodityName;

    @TableField("price")
    @ApiModelProperty(value = "商品价格")
    private BigDecimal price;

    @TableField("detail")
    @ApiModelProperty(value = "商品详情")
    private String detail;

    @TableField("num")
    @ApiModelProperty(value = "商品数量")
    private Integer num;

    @TableField("logoUrl")
    @ApiModelProperty(value = "商品图片")
    private String logoUrl;

    @TableField("releaseId")
    @ApiModelProperty(value = "发布者id")
    private String releaseId;

    /*@TableField(value = "createTime", fill = FieldFill.INSERT)
    @ApiModelProperty(value = "发布时间")
    private String createTime;

    @TableField(value = "updateTime", fill = FieldFill.INSERT_UPDATE)
    @ApiModelProperty(value = "最后更新时间")
    private String updateTime;*/

    @TableField("address")
    @ApiModelProperty(value = "发布地址")
    private String address;

    @TableField("shopType")
    @ApiModelProperty(value = "商品分类")
    private Integer shopType;


}
